home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Language/OS - Multiplatform Resource Library
/
LANGUAGE OS.iso
/
et
/
et3_0-a1.lha
/
et3
/
postscript
/
et-2.2-0.ps
next >
Wrap
Text File
|
1992-02-06
|
21KB
|
1,024 lines
%%BeginProcSet: et 2.2 0
%---- utilities -----------------------------------------------------------------
/ET++Dict 130 dict def
ET++Dict begin
%---- bdef ----------------------------------------------------------------------
/bdef {
bind def
} bind def
%---- ctoi ----------------------------------------------------------------------
/ctoi {
dup
127 gt {
256 sub
} if
} bdef
%---- SetPenSize ----------------------------------------------------------------
% psz SetPenSize -
/SetPenSize {
/psz exch def
} bdef
%---- cm ------------------------------------------------------------------------
% n cm n
/cm {
72 2.54 div mul
} bdef
%---- halftones and patterns ----------------------------------------------------
/$SetPattern-Dict 10 dict def
/setpattern {
$SetPattern-Dict begin
/bstring exch def
9.375 0 {
1 add 4 mul cvi bstring exch get exch
1 add 4 mul cvi 7 sub bitshift 1 and
} setscreen
/onbits 0 def
/offbits 0 def
0 1 63 {
/i exch def
bstring i 8 idiv get 1 7 i 8 mod sub bitshift and 0 ne {
/onbits onbits 1 add def
} {
/offbits offbits 1 add def
} ifelse
} for
offbits 64 div setgray
/setfreq true def
end
} bdef
$SetPattern-Dict begin
/setfreq false def
currentscreen
/spot exch def
/angle exch def
/freq exch def
end
%---- SetPattern ----------------------------------------------------------------
% hexstring SetPattern -
/SetPattern {
$SetPattern-Dict begin
setfreq {
freq angle /spot load setscreen
/setfreq false def
} if
setpattern
end
} bdef
%---- SetGray ------------------------------------------------------------------
% value SetGray -
/SetGray {
$SetPattern-Dict begin
setfreq {
freq angle /spot load setscreen
/setfreq false def
} if
setgray
end
} bdef
%---- FillRect ----------------------------------------------------------------
/$FillRect-Dict 5 dict def
% left top wd ht FillRect
/FillRect {
$FillRect-Dict begin
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def % save old matrix
left top translate
wd ht scale
newpath
0 0 moveto
1 0 lineto
1 1 lineto
0 1 lineto
closepath
svmx setmatrix % restore old matrix
fill
grestore
end
} bdef
%---- StrokeRect ----------------------------------------------------------------
/$StrokeRect-Dict 5 dict def
% left top wd ht StrokeRect
/StrokeRect {
$StrokeRect-Dict begin
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def % save old matrix
left psz 2 div add top psz 2 div add translate
wd psz sub ht psz sub scale
newpath
0 0 moveto
1 0 lineto
1 1 lineto
0 1 lineto
closepath
svmx setmatrix % restore old matrix
psz setlinewidth
% psz psz scale
stroke
grestore
end
} bdef
%---- FillPoly ----------------------------------------------------------------
/$FillPoly-Dict 11 dict def
% left top wd ht clos pts rwd rht spl FillPoly -
/FillPoly {
$FillPoly-Dict begin
/pts exch def
/rht exch def
/rwd exch def
/spl exch def
/clos exch def
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def
% left top ht add translate
% wd rwd div ht rht div neg scale
left top translate
wd rwd div ht rht div scale
newpath
pts 0 get pts 1 get moveto
spl 0 eq {
2 2 pts length 1 sub {
/i exch def
pts i get pts i 1 add get lineto
} for
} {
2 6 pts length 1 sub {
/i exch def
pts i get pts 1 i add get
pts 2 i add get pts 3 i add get
pts 4 i add get pts 5 i add get
curveto
} for
} ifelse
clos 1 eq {
closepath
} if
svmx setmatrix
eofill
grestore
end
} bdef
%---- StrokePoly ----------------------------------------------------------------
/$StrokePoly-Dict 11 dict def
% left top wd ht clos pts rwd rht spl StrokePoly -
/StrokePoly {
$StrokePoly-Dict begin
/pts exch def
/rht exch def
/rwd exch def
/spl exch def
/clos exch def
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def
% left top ht add translate
% wd rwd div ht rht div neg scale
left top translate
wd rwd div ht rht div scale
pts 0 get pts 1 get moveto
spl 0 eq {
2 2 pts length 1 sub {
/i exch def
pts i get pts i 1 add get lineto
} for
} {
2 6 pts length 1 sub {
/i exch def
pts i get pts 1 i add get
pts 2 i add get pts 3 i add get
pts 4 i add get pts 5 i add get
curveto
} for
} ifelse
clos 1 eq {
closepath
} if
svmx setmatrix
psz setlinewidth
stroke
grestore
end
} bdef
%---- docorner ------------------------------------------------------------------
/$docorner-dict 1 dict def
% startangle endangle xrad yrad xpos ypos docorner
/docorner {
$docorner-dict begin
/savematrix mtrx currentmatrix def
translate
scale
0 0 1 5 -2 roll arc
savematrix setmatrix
end
} bdef
%---- StrokeRoundRect ------------------------------------------------------------------
/$StrokeRoundRect-Dict 8 dict def
% left top wd ht owd oht StrokeRoundRect -
/StrokeRoundRect {
$StrokeRoundRect-Dict begin
/oht exch psz sub 2 div def
/owd exch psz sub 2 div def
/ht exch def
/wd exch def
/top exch def
/left exch def
/ht1 ht psz sub 2 div def
/wd1 wd psz sub 2 div def
gsave
left psz 2 div add wd1 add top psz 2 div add ht1 add translate
newpath
0 90 owd oht wd1 owd sub ht1 oht sub docorner
90 180 owd oht wd1 neg owd add ht1 oht sub docorner
180 270 owd oht wd1 neg owd add ht1 neg oht add docorner
270 360 owd oht wd1 owd sub ht1 neg oht add docorner
closepath
psz setlinewidth
stroke
grestore
end
} bdef
%---- FillRoundRect ------------------------------------------------------------------
/$FillRoundRect-Dict 8 dict def
% left top wd ht owd oht FillRoundRect -
/FillRoundRect {
$FillRoundRect-Dict begin
/oht exch 2 div def
/owd exch 2 div def
/ht exch def
/wd exch def
/top exch def
/left exch def
/ht1 ht 2 div def
/wd1 wd 2 div def
gsave
left wd1 add top ht1 add translate
newpath
0 90 owd oht wd1 owd sub ht1 oht sub docorner
90 180 owd oht wd1 neg owd add ht1 oht sub docorner
180 270 owd oht wd1 neg owd add ht1 neg oht add docorner
270 360 owd oht wd1 owd sub ht1 neg oht add docorner
closepath
fill
grestore
end
} bdef
%---- StrokeOval ------------------------------------------------------------------
/$StrokeOval-Dict 5 dict def
% left top wd ht StrokeOval -
/StrokeOval {
$StrokeOval-Dict begin
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def
left psz 2 div add top psz 2 div add translate
wd psz sub ht psz sub scale
newpath
0.5 0.5 0.5 0 360 arc
svmx setmatrix
psz setlinewidth
stroke
grestore
end
} bdef
%---- FillOval ------------------------------------------------------------------
/$FillOval-Dict 5 dict def
% left top wd ht FillOval -
/FillOval {
$FillOval-Dict begin
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def
left top translate
wd ht scale
newpath
0.5 0.5 0.5 0 360 arc
svmx setmatrix
fill
grestore
end
} bdef
%---- StrokeWedge ------------------------------------------------------------------
/$StrokeWedge-Dict 7 dict def
% left top wd ht startangle endangle StrokeWedge -
/StrokeWedge {
$StrokeWedge-Dict begin
/$end exch def
/$start exch def
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def
left psz 2 div add top psz 2 div add translate
wd psz sub ht psz sub scale
newpath
0.5 0.5 0.5 $start $end add 90 sub $start 90 sub arcn
svmx setmatrix
psz setlinewidth
stroke
grestore
end
} bdef
%---- StrokeWedge ------------------------------------------------------------------
/$FillWedge-Dict 7 dict def
% left top wd ht startangle endangle FillWedge -
/FillWedge {
$FillWedge-Dict begin
/$end exch def
/$start exch def
/ht exch def
/wd exch def
/top exch def
/left exch def
gsave
/svmx mtrx currentmatrix def
left top translate
wd ht scale
newpath
0.5 0.5 moveto
0.5 0.5 0.5 $start $end add 90 sub $start 90 sub arcn
svmx setmatrix
fill
grestore
end
} bdef
%---- StrokeArrow ---------------------------------------------------------------------
/$StrokeArrow-dict 14 dict def
% tipx tipy tailx taily mode StrokeArrow -
/StrokeArrow {
$StrokeArrow-dict begin
/mode exch def
/taily exch def
/tailx exch def
/tipy exch def
/tipx exch def
/lw psz def
/dx tipx tailx sub def
/dy tipy taily sub def
dx 0 eq dy 0 eq and {
/angle 180 def
} {
/angle dy dx atan def
} ifelse
/arrowlength dx dx mul dy dy mul add sqrt def
/aw2 lw 2 mul def
/ah lw 7 mul def
gsave
tailx taily translate
angle rotate
mode 2 and 2 eq {
newpath
0 0 moveto
ah aw2 lineto
ah aw2 neg lineto
closepath
fill
/x1 ah def
} {
/x1 0 def
} ifelse
mode 1 and 1 eq {
newpath
arrowlength 0 moveto
arrowlength ah sub aw2 lineto
arrowlength ah sub aw2 neg lineto
closepath
fill
/x2 arrowlength ah sub def
} {
/x2 arrowlength def
} ifelse
psz setlinewidth
newpath
x1 0 moveto
x2 0 lineto
stroke
grestore
end
} bdef
%---- SetClip -------------------------------------------------------------------
/$clip-dict 5 dict def
$clip-dict begin
/inclip false def
end
% ulx uly wd ht SetClip -
/SetClip {
$clip-dict begin
inclip { grestore } if
gsave
/inclip true def
/ht exch def
/wd exch def
/uly exch def
/ulx exch def
newpath
ulx uly moveto
wd 0 rlineto
0 ht rlineto
wd neg 0 rlineto
closepath
clip
newpath
end
} bdef
% - Restore -
/Restore {
$clip-dict begin
inclip { grestore } if
/inclip false def
restore
end
} bdef
%---- Bitmap ------------------------------------------------------------------
/$Bitmap-Dict 11 dict def
% ulx uly wd ht xbits ybits depth Bitmap -
/Bitmap {
gsave
$Bitmap-Dict begin
/depth exch def
/ybits exch def
/xbits exch def
/ht exch def
/wd exch def
/uly exch def
/ulx exch def
ulx uly translate
% wd xbits div ht ybits div scale
wd ht scale
/s xbits 1 sub 8 idiv 1 add string def
xbits
ybits
depth 1 eq { true } { depth } ifelse
[ xbits 0 0 ybits 0 0 ]
{ currentfile s readhexstring pop }
depth 1 eq { imagemask } { image } ifelse
end
grestore
} bdef
%---- SmoothBitmap --------------------------------------------------------------
/$SmoothBitmap-Dict 10 dict def
% scalex scaley ulx uly xbytes xbits SmoothBitmapStart
/SmoothBitmapStart {
$SmoothBitmap-Dict begin
gsave
/xbits exch def
/xbytes exch def
/ypos 0 def
translate
scale
} def
/SmoothBitmapEnd {
grestore
end
} def
% ybits Band -
/Band {
/ybits exch def
/@saveobj save def
0 ypos transform round 0.5 sub exch round 0.5 sub exch itransform
translate
xbits ybits scale
newpath
0 0 moveto
/s1 ybits 4 add xbytes mul string def
/s2 ybits xbytes mul 4 bitshift string def
/4xbits xbits 2 bitshift def
/4ybits ybits 2 bitshift def
xbytes 5 bitshift % 4 * number of xbits
4ybits % 4 * number of ybits
true
[ 4xbits 0 0 4ybits 8 0 ]
{
s2 % workspace
currentfile s1 readhexstring pop % read all at once
s2 % workspace
xbits 2 add % too bits wider
smooth % (stolen from laserprep: pssst!)
} imagemask
@saveobj restore
/ypos ypos ybits add def
} bdef
%---- sshow ---------------------------------------------------------------------
/$sshowdict 4 dict def
% (string) width sshow -
/sshow {
$sshowdict begin
/w exch def
/s exch def
/l s length 1 sub def
l 0 eq {
s show
} {
/rw s stringwidth pop def
w rw sub l div 0 s ashow
} ifelse
end
} bdef
%---- sshow ---------------------------------------------------------------------
/$bsshowdict 5 dict def
% (string) width blanks bsshow -
/bsshow {
$bsshowdict begin
/b exch def
/w exch def
/s exch def
/rw s stringwidth pop def
w rw sub b div 0 32 s widthshow
end
} bdef
%---- addchar -------------------------------------------------------------------
/$addchar-dict 3 dict def
/addchar {
$addchar-dict begin
/charnum exch def
/metrics exch def
/charname MacEncoding charnum get def
Encoding charnum charname put
CharData begin
charname metrics def
end
end
} def
%---- newbitmapfont -------------------------------------------------------------
/$newbitmapfont-dict 20 dict def
% fontname fid ps chars char_no llx lly urx ury newbitmapfont
/newbitmapfont {
$newbitmapfont-dict begin
/ury exch def
/urx exch def
/lly exch def
/llx exch def
/chnos exch def
/all exch def
/pps exch def
/fid exch def
/fname exch def
20 dict dup begin
/FontType 3 def
/FontMatrix [ 1 0 0 1 0 0 ] def
/FontBBox [ llx pps div lly pps div urx pps div ury pps div ] def
/Encoding 256 array def
/UniqueID fid def
/ps pps def
0 1 255 {
Encoding exch /.notdef put
} for
/BuildChar {
0 begin
/char exch def
/fontdict exch def
/charname fontdict /Encoding get char get def
/charinfo fontdict /CharData get charname get def
/ps fontdict /ps get def
/wx charinfo 0 get def
/w charinfo 1 get def
/h charinfo 2 get def
/ox charinfo 3 get ctoi def
/oy charinfo 4 get ctoi def
wx ps div
0
ox ps div
oy ps div
ox w add ps div
oy neg h add ps div
setcachedevice
w
h
true
[
ps
0
0
ps neg
ox neg 0.5 sub
h oy add 0.5 sub
]
{ charinfo 5 charinfo length 5 sub getinterval }
imagemask
end
} def
/BuildChar load 0 10 dict put
/CharData chnos 1 add dict def
CharData begin
/.notdef <0F00000000> def
end
all {
dup dup 1 exch length 1 sub getinterval
exch 0 get
addchar
} forall
end
fname exch
end
definefont pop
} def
%---- newsmoothedbitmapfont -------------------------------------------------------------
/$newsmoothedbitmapfont-dict 20 dict def
% fontname fid ps chars char_no llx lly urx ury newbitmapfont
/newsmoothedbitmapfont {
$newsmoothedbitmapfont-dict begin
/ury exch def
/urx exch def
/lly exch def
/llx exch def
/chnos exch def
/all exch def
/pps exch def
/fid exch def
/fname exch def
20 dict dup begin
/FontType 3 def
/FontMatrix [ 1 0 0 1 0 0 ] def
/FontBBox [ llx pps div lly pps div urx pps div ury pps div ] def
/Encoding 256 array def
/UniqueID fid def
/ps pps def
0 1 255 {
Encoding exch /.notdef put
} for
/BuildChar {
0 begin
/char exch def
/fontdict exch def
/charname fontdict /Encoding get char get def
/charinfo fontdict /CharData get charname get def
/ps fontdict /ps get def
/wx charinfo 0 get def
/w charinfo 1 get def
/h charinfo 2 get def
/ox charinfo 3 get ctoi def
/oy charinfo 4 get ctoi def
/l charinfo length 5 sub def
/s1 charinfo 5 l getinterval def
/xbytes l h 4 add idiv def
/s2 h xbytes mul 16 mul string def
wx ps div
0
ox ps div
oy ps div
ox w add ps div
oy neg h add ps div
setcachedevice
xbytes 32 mul
h 4 mul
true
[
ps 4 mul
0
0
ps 4 mul neg
% ox neg 0.5 sub 4 mul
ox neg 2 add 4 mul
%h oy add 0.5 sub 4 mul
h oy add 4 mul
]
{
s2
s1
s2
w 2 add
smooth
}
imagemask
end
} def
/BuildChar load 0 20 dict put
/CharData chnos 1 add dict def
CharData begin
/.notdef <0F00000000> def
end
all {
dup dup 1 exch length 1 sub getinterval
exch 0 get
addchar
} forall
end
fname exch
end
definefont pop
} def
%--------------------------------------------------------------------------------
/$reenc-dict 6 dict def
/Reencode {
$reenc-dict begin
/basefontname exch def
/basefont basefontname load exec def
/oldfontname basefont /FontName get dup length string cvs def
/newfontname oldfontname length 1 add string def % create string
oldfontname newfontname copy pop % copy old name to new name
newfontname oldfontname length 88 put % append "X"
/newfont basefont maxlength dict def % define new font dict
basefont {
exch dup /FID ne {
dup /Encoding eq {
exch dup length array copy
newfont 3 1 roll put
} {
exch newfont 3 1 roll put
} ifelse
} {
pop pop
} ifelse
} forall
newfont /FontName newfontname put % set new fontname
newfont /Encoding MacEncoding put
newfontname newfont definefont pop
basefontname newfontname
end
findfont def
} bdef
%---- scalesetfont --------------------------------------------------------------
/fontmtx [ 1 0 0 -1 0 0 ] def
% font ps scalesetfont -
/scalesetfont {
scalefont fontmtx makefont setfont
} bdef
%---- m -------------------------------------------------------------------------
% hpos vpos m -
/m {
moveto
} bdef
%---- init ----------------------------------------------------------------------
/$init-dict 4 dict def
% tx ty rot scalexy init -
/init {
$init-dict begin
/scalexy exch def
/rot exch def
/ty exch def
/tx exch def
tx ty translate
rot rotate
scalexy scalexy neg scale
end
} bdef
%---- strokeBBox ----------------------------------------------------------------
/$StrokeBBox-dict 4 dict def
% llx lly urx ury StrokeBBox -
/StrokeBBox {
$StrokeBBox-dict begin
/ury exch def
/urx exch def
/lly exch def
/llx exch def
gsave
0 setlinewidth
newpath
llx lly moveto
llx ury lineto
urx ury lineto
urx lly lineto
closepath
stroke
grestore
end
} bdef
%---- EPSF ----------------------------------------------------------------------
/BeginEPSF {
/b4_Inc_state save def
/dict_count countdictstack def
/op_count count 1 sub def
userdict begin
/showpage { } def
0 setgray 0 setlinecap
1 setlinewidth 0 setlinejoin
10 setmiterlimit [] 0 setdash newpath
/laguagelevel where {
pop languagelevel 1 ne {
false strokeadjust false setoverprint
} if
} if
} bdef
/EndEPSF {
count op_count sub { pop } repeat
countdictstack dict_count sub { end } repeat
b4_Inc_state restore
} bdef
%---- make encoding vector ------------------------------------------------------
/MacEncoding 256 array def
MacEncoding 0 /Times-Roman findfont /Encoding get 0 128 getinterval putinterval
MacEncoding 17 /blumenkohl put
MacEncoding 18 /checkmark put
MacEncoding 19 /diamond put
MacEncoding 20 /applelogo put
MacEncoding 21 /applelogo1 put
MacEncoding 22 /menuarrow put
MacEncoding 39 /quotesingle put
MacEncoding 96 /grave put
/Adieresis /Aring /Ccedilla /Eacute /Ntilde /Odieresis /Udieresis /aacute
/agrave /acircumflex /adieresis /atilde /aring /ccedilla /eacute /egrave
/ecircumflex /edieresis /iacute /igrave /icircumflex /idieresis /ntilde
/oacute /ograve /ocircumflex /odieresis /otilde /uacute /ugrave /ucircumflex
/udieresis /dagger /degree /cent /sterling /section /bullet /paragraph
/germandbls /registersans /copyrightsans /trademarksans /acute /dieresis
/notequal /AE /Oslash /infinity /plusminus /lessequal /greaterequal /yen /mu
/partialdiff /summation /product /pi /integral /ordfeminine /ordmasculine
/Omega /ae /oslash /questiondown /exclamdown /logicalnot /radical /florin
/approxequal /Delta /guillemotleft /guillemotright /ellipsis /space /Aacute
/Atilde /Otilde /OE /oe /endash /emdash /quotedblleft /quotedblright
/quoteleft /quoteright /divide /lozenge /ydieresis /Ydieresis /fraction
/currency /guilsinglleft /guilsinglright /fi /fl /daggerdbl /periodcentered
/quotesinglbase /quotedblbase /perthousand /Acircumflex /Ecircumflex /Agrave
/Edieresis /Egrave /Iacute /Icircumflex /Idieresis /Igrave /Oacute
/Ocircumflex /apple /Ograve /Uacute /Ucircumflex /Ugrave /dotlessi /circumflex
/tilde /macron /breve /dotaccent /ring /cedilla /hungarumlaut /ogonek /caron
MacEncoding 128 128 getinterval astore pop
%--------------------------------------------------------------------------------
/mtrx matrix def
end
%%EndProcSet